/*
 * 
 *  jiangcheng
 *  
 */

package com.uhaou.web.model;

import javax.validation.constraints.*;
import org.hibernate.validator.constraints.*;
import org.apache.commons.lang.builder.EqualsBuilder;
import org.apache.commons.lang.builder.HashCodeBuilder;
import org.apache.commons.lang.builder.ToStringBuilder;
import org.apache.commons.lang.builder.ToStringStyle;

import java.util.*;
import org.apache.commons.lang.StringUtils;

import com.uhaou.common.base.*;
import com.uhaou.common.util.*;

import cn.org.rapid_framework.util.*;
import cn.org.rapid_framework.web.util.*;
import cn.org.rapid_framework.page.*;
import cn.org.rapid_framework.page.impl.*;

import com.uhaou.web.model.*;
import com.uhaou.web.dao.*;
import com.uhaou.web.service.*;
import com.uhaou.web.vo.query.*;

/**
 * @author  jiangcheng
 * @version 1.0
 * @since 1.0
 */


public class WebImg extends BaseEntity implements java.io.Serializable {
	private static final long serialVersionUID = 5454155825314635342L;
	
	//alias
	public static final String TABLE_ALIAS = "WebImg";
	public static final String ALIAS_ID = "id";
	public static final String ALIAS_IMG_NAME = "imgName";
	public static final String ALIAS_IMG_URL = "imgUrl";
	public static final String ALIAS_CREATOR = "creator";
	public static final String ALIAS_GROUP_ID = "groupId";
	public static final String ALIAS_THEME_ID = "themeId";
	
	//date formats
	
	//可以直接使用: @Length(max=50,message="用户名长度不能大于50")显示错误消息
	//columns START
	@Length(max=32)
	private java.lang.String id;
	@Length(max=100)
	private java.lang.String imgName;
	@Length(max=200)
	private java.lang.String imgUrl;
	@Length(max=32)
	private java.lang.String creator;
	@Length(max=32)
	private java.lang.String groupId;
	@Length(max=32)
	private java.lang.String themeId;
	//columns END

	public WebImg(){
	}

	public WebImg(
		java.lang.String id
	){
		this.id = id;
	}

	public void setId(java.lang.String value) {
		this.id = value;
	}
	
	public java.lang.String getId() {
		return this.id;
	}
	public void setImgName(java.lang.String value) {
		this.imgName = value;
	}
	
	public java.lang.String getImgName() {
		return this.imgName;
	}
	public void setImgUrl(java.lang.String value) {
		this.imgUrl = value;
	}
	
	public java.lang.String getImgUrl() {
		return this.imgUrl;
	}
	public void setCreator(java.lang.String value) {
		this.creator = value;
	}
	
	public java.lang.String getCreator() {
		return this.creator;
	}
	public void setGroupId(java.lang.String value) {
		this.groupId = value;
	}
	
	public java.lang.String getGroupId() {
		return this.groupId;
	}
	public void setThemeId(java.lang.String value) {
		this.themeId = value;
	}
	
	public java.lang.String getThemeId() {
		return this.themeId;
	}

	public String toString() {
		return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
			.append("Id",getId())
			.append("ImgName",getImgName())
			.append("ImgUrl",getImgUrl())
			.append("Creator",getCreator())
			.append("GroupId",getGroupId())
			.append("ThemeId",getThemeId())
			.toString();
	}
	
	public int hashCode() {
		return new HashCodeBuilder()
			.append(getId())
			.toHashCode();
	}
	
	public boolean equals(Object obj) {
		if(obj instanceof WebImg == false) return false;
		if(this == obj) return true;
		WebImg other = (WebImg)obj;
		return new EqualsBuilder()
			.append(getId(),other.getId())
			.isEquals();
	}
}

